home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
C++ für Kids
/
C++ for kids.iso
/
SETUP
/
US
/
CBUILDER
/
DATA.Z
/
FILECTRL.HPP
< prev
next >
Wrap
C/C++ Source or Header
|
1997-02-13
|
15KB
|
421 lines
//----------------------------------------------------------------------------
// FileCtrl.hpp - bcbdcc32 generated hdr (DO NOT EDIT) rev: 0
// From: FileCtrl.pas
//----------------------------------------------------------------------------
#ifndef FileCtrlHPP
#define FileCtrlHPP
//----------------------------------------------------------------------------
#include <Buttons.hpp>
#include <StdCtrls.hpp>
#include <Menus.hpp>
#include <Forms.hpp>
#include <Graphics.hpp>
#include <Controls.hpp>
#include <Classes.hpp>
#include <SysUtils.hpp>
#include <Messages.hpp>
#include <Windows.hpp>
#include <System.hpp>
#pragma warn -par
#pragma warn -hid
#pragma warn -inl
namespace Filectrl
{
//-- type declarations -------------------------------------------------------
enum TFileAttr { ftReadOnly, ftHidden, ftSystem, ftVolumeID, ftDirectory, ftArchive, ftNormal };
typedef Set<TFileAttr, ftReadOnly, ftNormal> TFileType;
enum TDriveType { dtUnknown, dtNoDrive, dtFloppy, dtFixed, dtNetwork, dtCDROM, dtRAM };
class __declspec(delphiclass) TFileListBox;
class __declspec(delphiclass) TDirectoryListBox;
class __declspec(delphiclass) TDriveComboBox;
enum TTextCase { tcLowerCase, tcUpperCase };
class __declspec(pascalimplementation) TDriveComboBox : public Stdctrls::TCustomComboBox
{
typedef Stdctrls::TCustomComboBox inherited;
private:
TDirectoryListBox* FDirList;
char FDrive;
TTextCase FTextCase;
void __fastcall SetDirListBox(TDirectoryListBox* Value);
HIDESBASE MESSAGE void __fastcall CMFontChanged(Messages::TMessage &Message);
void __fastcall SetDrive(char NewDrive);
void __fastcall SetTextCase(TTextCase NewTextCase);
void __fastcall ReadBitmaps(void);
void __fastcall ResetItemHeight(void);
protected:
Graphics::TBitmap* FloppyBMP;
Graphics::TBitmap* FixedBMP;
Graphics::TBitmap* NetworkBMP;
Graphics::TBitmap* CDROMBMP;
Graphics::TBitmap* RAMBMP;
Classes::TNotifyEvent FOnChange;
virtual void __fastcall CreateWnd(void);
virtual void __fastcall DrawItem(int Index, const Windows::TRect &Rect, Stdctrls::TOwnerDrawState State
);
virtual void __fastcall Click(void);
virtual void __fastcall BuildList(void);
virtual void __fastcall Notification(Classes::TComponent* AComponent, Classes::TOperation Operation
);
HIDESBASE virtual void __fastcall Change(void);
public:
__fastcall virtual TDriveComboBox(Classes::TComponent* AOwner);
__fastcall virtual ~TDriveComboBox(void);
__property Text ;
__property char Drive = {read=FDrive, write=SetDrive, nodefault};
__published:
__property Color ;
__property Ctl3D ;
__property TDirectoryListBox* DirList = {read=FDirList, write=SetDirListBox, nodefault};
__property DragMode ;
__property DragCursor ;
__property Enabled ;
__property Font ;
__property ImeMode ;
__property ImeName ;
__property ParentColor ;
__property ParentCtl3D ;
__property ParentFont ;
__property ParentShowHint ;
__property PopupMenu ;
__property ShowHint ;
__property TabOrder ;
__property TabStop ;
__property TTextCase TextCase = {read=FTextCase, write=SetTextCase, default=0};
__property Visible ;
__property Classes::TNotifyEvent OnChange = {read=FOnChange, write=FOnChange};
__property OnClick ;
__property OnDblClick ;
__property OnDragDrop ;
__property OnDragOver ;
__property OnDropDown ;
__property OnEndDrag ;
__property OnEnter ;
__property OnExit ;
__property OnKeyDown ;
__property OnKeyPress ;
__property OnKeyUp ;
__property OnStartDrag ;
public:
/* TWinControl.CreateParented */ __fastcall TDriveComboBox(HWND ParentWindow) : Stdctrls::TCustomComboBox(
ParentWindow) { }
};
class __declspec(delphiclass) TFolderBitmap;
class __declspec(pascalimplementation) TFolderBitmap : public Graphics::TBitmap
{
typedef Graphics::TBitmap inherited;
public:
__fastcall TFolderBitmap(void);
public:
/* TBitmap.Destroy */ __fastcall virtual ~TFolderBitmap(void) { }
};
class __declspec(pascalimplementation) TDirectoryListBox : public Stdctrls::TCustomListBox
{
typedef Stdctrls::TCustomListBox inherited;
private:
TFileListBox* FFileList;
TDriveComboBox* FDriveCombo;
Stdctrls::TLabel* FDirLabel;
bool FInSetDir;
bool FPreserveCase;
bool FCaseSensitive;
char __fastcall GetDrive(void);
void __fastcall SetFileListBox(TFileListBox* Value);
void __fastcall SetDirLabel(Stdctrls::TLabel* Value);
void __fastcall SetDirLabelCaption(void);
HIDESBASE MESSAGE void __fastcall CMFontChanged(Messages::TMessage &Message);
void __fastcall SetDrive(char Value);
void __fastcall DriveChange(char NewDrive);
void __fastcall SetDir(const System::AnsiString NewDirectory);
virtual void __fastcall SetDirectory(const System::AnsiString NewDirectory);
void __fastcall ResetItemHeight(void);
protected:
TFolderBitmap* ClosedBMP;
TFolderBitmap* OpenedBMP;
TFolderBitmap* CurrentBMP;
System::AnsiString FDirectory;
Classes::TNotifyEvent FOnChange;
virtual void __fastcall Change(void);
virtual void __fastcall DblClick(void);
virtual void __fastcall ReadBitmaps(void);
virtual void __fastcall CreateWnd(void);
virtual void __fastcall DrawItem(int Index, const Windows::TRect &Rect, Stdctrls::TOwnerDrawState State
);
int __fastcall ReadDirectoryNames(const System::AnsiString ParentDirectory, Classes::TStringList* DirectoryList
);
virtual void __fastcall BuildList(void);
virtual void __fastcall KeyPress(char &Key);
virtual void __fastcall Notification(Classes::TComponent* AComponent, Classes::TOperation Operation
);
public:
__fastcall virtual TDirectoryListBox(Classes::TComponent* AOwner);
__fastcall virtual ~TDirectoryListBox(void);
System::AnsiString __fastcall DisplayCase(const System::AnsiString S);
int __fastcall FileCompareText(const System::AnsiString A, const System::AnsiString B);
System::AnsiString __fastcall GetItemPath(int Index);
void __fastcall OpenCurrent(void);
HIDESBASE void __fastcall Update(void);
__property char Drive = {read=GetDrive, write=SetDrive, nodefault};
__property System::AnsiString Directory = {read=FDirectory, write=SetDirectory, nodefault};
__property bool PreserveCase = {read=FPreserveCase, nodefault};
__property bool CaseSensitive = {read=FCaseSensitive, nodefault};
__published:
__property Align ;
__property Color ;
__property Columns ;
__property Ctl3D ;
__property Stdctrls::TLabel* DirLabel = {read=FDirLabel, write=SetDirLabel, nodefault};
__property DragCursor ;
__property DragMode ;
__property Enabled ;
__property TFileListBox* FileList = {read=FFileList, write=SetFileListBox, nodefault};
__property Font ;
__property ImeMode ;
__property ImeName ;
__property IntegralHeight ;
__property ItemHeight ;
__property ParentColor ;
__property ParentCtl3D ;
__property ParentFont ;
__property ParentShowHint ;
__property PopupMenu ;
__property ShowHint ;
__property TabOrder ;
__property TabStop ;
__property Visible ;
__property Classes::TNotifyEvent OnChange = {read=FOnChange, write=FOnChange};
__property OnClick ;
__property OnDblClick ;
__property OnDragDrop ;
__property OnDragOver ;
__property OnEndDrag ;
__property OnEnter ;
__property OnExit ;
__property OnKeyDown ;
__property OnKeyPress ;
__property OnKeyUp ;
__property OnMouseDown ;
__property OnMouseMove ;
__property OnMouseUp ;
__property OnStartDrag ;
public:
/* TWinControl.CreateParented */ __fastcall TDirectoryListBox(HWND ParentWindow) : Stdctrls::TCustomListBox(
ParentWindow) { }
};
class __declspec(delphiclass) TFilterComboBox;
class __declspec(pascalimplementation) TFilterComboBox : public Stdctrls::TCustomComboBox
{
typedef Stdctrls::TCustomComboBox inherited;
private:
System::AnsiString FFilter;
TFileListBox* FFileList;
Classes::TStringList* MaskList;
bool __fastcall IsFilterStored(void);
System::AnsiString __fastcall GetMask(void);
void __fastcall SetFilter(const System::AnsiString NewFilter);
void __fastcall SetFileListBox(TFileListBox* Value);
protected:
Classes::TNotifyEvent FOnChange;
virt